/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package services;


import services.interfaces.ITableService;

import java.util.ArrayList;

import java.util.Date;
import java.util.List;
import javax.persistence.EntityManager;
import javax.persistence.PersistenceContext;
import models.Tables;
import models.Orders;
import services.interfaces.IOrdersService;

/**
 *
 * @author Yaroslav
 */
public class TablesServiceImpl extends GenericServiceImpl<Tables> implements ITableService {

    @PersistenceContext(unitName="ors-ejbPU2")
    private EntityManager em;
    
    public TablesServiceImpl() {
        super(Tables.class);
    }
    
    private List<Tables> listTables = new ArrayList<Tables>();
             
             
    @Override
    public List<Tables> getFreeTables(Date dateTime) {
         return null;
    
        
            
          /*   List<Tables> listTables = this.listTables;
        IOrdersService os = new OrdersServiceImpl(); 
        listTables.removeAll(os.getOrderedTables(dateTime));
        return listTables;
        */
    }

    @Override
    protected EntityManager getEntityManager() {
        throw new UnsupportedOperationException("Not supported yet.");
    }

    @Override
    public int count() {
        throw new UnsupportedOperationException("Not supported yet.");
    }

    @Override
    public boolean addTableToOrders(Orders order, Tables tables) {
        throw new UnsupportedOperationException("Not supported yet.");
    }

    @Override
    public List<Tables> getOrdersTables(Orders order) {
        throw new UnsupportedOperationException("Not supported yet.");
    }

 
}
